<% args = params.clone %>
<% entry_name ||= nil %>

<% if defined?(per_page_action) %>
  <% args[:action] = per_page_action %>
<% end %>

<% if collection.any? && collection.total_pages > 1 %>
  <div class="py-2 border-top">
    <div class="index-pagination-row d-flex align-items-center">
      <div class="col-6 col-lg-3">
        <%= per_page_dropdown %>
      </div>
      <div class="d-none d-lg-block col-lg-6 text-center text-muted small">
        <%= page_entries_info(collection, entry_name: entry_name) %>
      </div>
      <div class="col-6 col-lg-3 text-right pr-lg-2">
        <%= paginate collection, theme: 'admin-twitter-bootstrap-4' %>
      </div>
    </div>
  </div>
<% end %>
